/*
 * Copyright 2007, Sualeh Fatehi <sualeh@hotmail.com>
 * 
 * This work is licensed under the Creative Commons Attribution 3.0 License. 
 * To view a copy of this license, visit 
 * http://creativecommons.org/licenses/by/3.0/ 
 * or send a letter to 
 * Creative Commons
 * 171 Second Street, Suite 300, San Francisco, California, 94105, USA.
 */
package sf.domain;


import java.io.Serializable;
import java.util.Date;

import javax.persistence.Basic;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

@Entity
public class Event
  implements Serializable
{
  private Long id;
  private int duration;
  private String name;
  private Date startDate;

  public int getDuration()
  {
    return duration;
  }

  @Id
  @GeneratedValue(strategy = GenerationType.AUTO)
  public Long getId()
  {
    return id;
  }

  @Basic
  public String getName()
  {
    return name;
  }

  @Temporal(value = TemporalType.TIMESTAMP)
  public Date getStartDate()
  {
    return startDate;
  }

  public void setDuration(final int duration)
  {
    this.duration = duration;
  }

  public void setId(final Long id)
  {
    this.id = id;
  }

  public void setName(final String name)
  {
    this.name = name;
  }

  public void setStartDate(final Date startDate)
  {
    this.startDate = startDate;
  }

}
